class Student{
    private String name;
    private int age;

    public Student(String name, int age) {
        this.name = name;
        this.age = age;
    }
}
public class Main {
    public static void main(String[] args) throws ClassNotFoundException {
        System.out.println("Hello world!");
        Class<?> c1 = Class.forName("Student"); //  forName 这是一个受查异常，必须在编译的时候就需要报错
        Class<?> c2 = Student.class; // 第二种方法获得class对象
        // 第三种方法
        Student student = new Student("zhangsan",12);
        Class<?> c3 = student.getClass();
        System.out.println(c1 == c2);
        System.out.println(c1 == c3);
        System.out.println(c3 == c2);
        //**** 得出的第一个结论就是 一个类只能拥有一个class对象 ****


    }
}